export default {
  async install(app) {
    const directives = import.meta.glob('./modules/*.js')
    for (const [key, value] of Object.entries(directives)) {
      // 异步需要等待
      const d = await value()
      const name = key.split('/')[2].split('.')[0]
      app.directive(name, d.default)
    }
  }
}
